﻿namespace IslandUnit.Providers
{
    /// <summary>
    /// Base class for IoC container providers
    /// </summary>
    public abstract class ContainerProviderBase
    {
        /// <summary>
        /// Initialize the container.
        /// </summary>
        public abstract object InitializeContainer();

        /// <summary>
        /// Binds the dependency interface to the mocked object.
        /// </summary>
        /// <typeparam name="TDependency">The type of the dependency.</typeparam>
        /// <param name="container">The IoC container.</param>
        /// <param name="mockedObject">The mocked object.</param>
        public abstract void Bind<TDependency>(object container, TDependency mockedObject) where TDependency : class;

        /// <summary>
        /// Get an object of the type T with dependencies from container.
        /// </summary>
        public abstract T Get<T>(object container);
    }

}